/*
 * test.cpp
 *
 * Helpers for tests within Arduino framework
 */

#include <WProgram.h>
#include "test.h"

extern "C" void __cxa_pure_virtual() {
	while (1)
		;
}

void print_hex(uint16_t num) {
	Serial.print("0x");
	Serial.print(num, 16);
	Serial.print(" ");
}

void print_msg(PGM_P msg) {
	static char serial_buf[120];
	strncpy_P(serial_buf, msg, 120);
	Serial.print(serial_buf);
}


void setup(void) {
	Serial.begin(57600);
}


void loop(void) {
	run_tests();
}
